#include <stdio.h>
#include <string.h>
int main()
{   char* p1[10]={0};
	char arr[20] = "I like Beijing.";
	char arr1[40]={0};
	char arr2[40]={0};
	int i=0;
	int j=0;
	strcpy(arr1,arr);
	const char *sep=" ";
	char *p=strtok(arr1,sep);
	while(p!=NULL)
	{   
	    p1[i++]=p;
		p=strtok(NULL,sep);
	}
	for(j=i-1;j>=0;j--)
	{
		strcat(arr2,p1[j]);
		strcat(arr2," ");
	}
	printf("%s",arr2);
	return 0;
}
